﻿/*
 * This software is the confidential and proprietary
 * information of NetBay
 * Such confidential information should not be disclosed
 * NetBay copyright(c) 2010
 */

#region Using
using System;
using System.Runtime.Serialization;
using System.Text;
#endregion

namespace NetBay.Core.BusinessEntities
{
    [DataContract]
    /// <summary>
    /// Class handle a StateMessageFlow (one row of r_doc_etat_group table)
    /// <remarks>
    /// Columns :
    ///     RD_NO               (long)
    ///     RGU_ID              (long)
    ///     MSG_FLOW_ID         (long)
    ///     DATE_ADD            (DateTime)
    ///     DOC_ETAT_ID         (long)
    ///     DOC_ETAT_LIBELLE    (string)
    /// </remarks>
    /// </summary>
    public class StateMessageFlow : ReturnObject
    {
        #region Private members

        /// <summary>
        /// RD_NO
        /// </summary>
        private long m_lRdNo;
        [DataMember]
        public long RdNo
        {
            get { return m_lRdNo; }
            set { m_lRdNo = value; }
        }

        /// <summary>
        /// RGU_ID
        /// </summary>
        private long m_lRguId;
        [DataMember]
        public long RguId
        {
            get { return m_lRguId; }
            set { m_lRguId = value; }
        }

        /// <summary>
        /// MSG_FLOW_ID
        /// </summary>
        private long m_lFlowId;
        [DataMember]
        public long FlowId
        {
            get { return m_lFlowId; }
            set { m_lFlowId = value; }
        }

        /// <summary>
        /// Comment
        /// </summary>
        private string m_sFlowTitle;
        [DataMember]
        public string MessageFlowTitle
        {
            get { return m_sFlowTitle; }
            set { m_sFlowTitle = value; }
        }

        /// <summary>
        /// DATE_ADD
        /// </summary>
        private DateTime m_oDateAdded;
        [DataMember]
        public DateTime DateAdded
        {
            get { return m_oDateAdded; }
            set { m_oDateAdded = value; }
        }

        /// <summary>
        /// DOC_ETAT_ID
        /// </summary>
        private long m_lStateId;
        [DataMember]
        public long StateId
        {
            get { return m_lStateId; }
            set { m_lStateId = value; }
        }

        /// <summary>
        /// DOC_ETAT_LIBELLE
        /// </summary>
        private string m_szWordingStateDoc;
        [DataMember]
        public string WordingStateDoc
        {
            get { return m_szWordingStateDoc; }
            set { m_szWordingStateDoc = value; }
        }

        /// <summary>
        /// User first name
        /// </summary>
        private string m_sFirstName;
        [DataMember]
        public string FirstName
        {
            get { return m_sFirstName; }
            set { m_sFirstName = value; }
        }

        /// <summary>
        /// User last name
        /// </summary>
        private string m_sLastName;
        [DataMember]
        public string LastName
        {
            get { return m_sLastName; }
            set { m_sLastName = value; }
        }
        
        /// <summary>
        /// Comment
        /// </summary>
        private string m_sComment;
        [DataMember]
        public string Comment
        {
            get { return m_sComment; }
            set { m_sComment = value; }
        }
                
        #endregion

        #region Init/Constructor
        /// <summary>
        /// Default constructor 
        /// </summary>
        public StateMessageFlow()
        {
        }

        /// <summary>
        /// Initializes a new instance of the <see cref="Folder"/> class for error usages
        /// </summary>
        /// <param name="errorMessage">The error message.</param>
        /// <param name="applicationException">The application exception.</param>
        public StateMessageFlow(string errorMessage, Exception applicationException = null)
            : base(errorMessage, applicationException)
        {
        }
        #endregion

        #region ToString
        /// <summary>
        /// Extend default description of class
        /// </summary>
        /// <returns>description of instance</returns>
        public override string ToString()
        {
            StringBuilder parameters = new StringBuilder("RdNo<", 4096);
            parameters.Append(RdNo); parameters.Append("> ");
            parameters.Append("RguId<"); parameters.Append(RguId); parameters.Append("> ");
            parameters.Append("FlowId<"); parameters.Append(FlowId); parameters.Append("> ");
            parameters.Append("DateAdded<"); parameters.Append(DateAdded); parameters.Append("> ");
            parameters.Append("StateId<"); parameters.Append(StateId); parameters.Append("> ");
            parameters.Append("WordingStateDoc<"); parameters.Append(WordingStateDoc); parameters.Append("> ");
            parameters.Append("FirstName<"); parameters.Append(FirstName); parameters.Append("> ");
            parameters.Append("LastName<"); parameters.Append(LastName); parameters.Append("> ");
            return parameters.ToString();
        }
        #endregion

        public override object Clone()
        {
            throw new NotImplementedException();
        }
    }
}


